<template>
	<view class="tixian">
		<view class="top">
			<image src='../../static/businessImg/back.png' class="topback" @click="back">
			</image>
			<view class="topname">
				提现记录
			</view>
		
		</view>
		
		<view class="orderlistview">
			<view class="orderlistItem" v-for="i in list">
				<view class="orderlistItemflex">
					<view class="orderlistItem_title">
						提现
					</view>
					<view class="orderlistItem_money">
						+{{i.price}}
					</view>
				</view>
				
				<view class="orderlistItemflex2">
					<view class="orderlistItem_name">
						{{i.status == 0 ? '审核中' : i.status == 1 ? '审核通过' : '审核拒绝'}}
					</view>
					
					<view class="orderlistItem_time">
						{{i.createTime}}
					</view>
				</view>
				
				
			</view>
		</view>
	</view>
</template>

<script>
	import storage from '@/utils/storage.js';
	import { withdrawalList } from '@/api/fenxiao.js'
	export default {
		data() {
			return {
				list: [],
				page: 1,
				limit: 10
			}
		},
		
		mounted() {
			this.getList()
		},
		
		onReachBottom() {
			this.page ++ ;
			this.getList()
		},
		methods: {
			back() {
				uni.navigateBack()
			},
			
			getList(){
				uni.showLoading();
				withdrawalList({
					page: this.page,
					limit: this.limit,
					storeId: storage.getUserInfo().storeId
				}).then(res => {
					if(res.code == '000000'){
						this.list = [...this.list,...res.data.list]
					}
					
				})
			}
		}
	}
</script>

<style scoped>
	.tixian {
		width: 100%;
		min-height: 100vh;
		
	}

	.top {
		width: 100%;
		height: 188rpx;
		position: relative;
		background: #FFFFFF;
	}

	.topback {
		width: 16rpx;
		height: 29rpx;
		position: absolute;
		top: 106rpx;
		left: 32rpx;
	}

	.topname {
		width: 300rpx;
		height: 32rpx;
		text-align: center;
		font-family: Adobe Heiti Std;
		font-weight: normal;
		font-size: 33rpx;
		color: #222222;
		line-height: 32rpx;
		position: absolute;
		top: 104rpx;
		left: 50%;
		transform: translateX(-50%);
	}
	
	.orderlistview {
		width: 100%;
		padding: 30rpx;
		margin-top: 20rpx;
	}
	.orderlistItem {
		width: 100%;
		height: 133rpx;
		background: #ffffff;
		border-radius: 15rpx;
		margin-bottom: 36rpx;
	}
	
	.orderlistItemflex {
		width: 100%;
		height: 28rpx;
		padding: 50rpx 30rpx 0 30rpx;
		display: flex;
		align-items: center;
		justify-content: space-between;
	}
	
	.orderlistItemflex2 {
		width: 100%;
		height: 28rpx;
		padding: 0 30rpx;
		display: flex;
		align-items: center;
		justify-content: space-between;
		margin-top: 30rpx;
	}
	
	.orderlistItem_title {
		font-family: Microsoft YaHei;
		font-weight: 400;
		font-size: 28rpx;
		color: #333333;
		width: 60%;
	}
	
	.orderlistItem_money {
		flex: 1;
		text-align: right;
		font-family: Source Han Sans CN;
		font-weight: 400;
		font-size: 28rpx;
		color: #FE3F10;
	}
	
	.orderlistItem_name {
		font-family: Microsoft YaHei;
		font-weight: 400;
		font-size: 24rpx;
		color: #808080;
	}
	
	.orderlistItem_time {
		font-family: inpinheiti;
		font-weight: 400;
		font-size: 24rpx;
		color: #808080;
	}

</style>
